summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMai <mai.iam2048@gmail.com>2023-02-08 04:10:35 +0100
committerGitHub <noreply@github.com>2023-02-08 04:10:35 +0100
commitf3b532d0915feb763f09b4900511c735c6b60693 (patch)
tree3809193e7b0554cd39998fb3fb4cb2929b9ee8d7
parentMerge pull request #4949 from Morph1984/hidpi-temp-fix (diff)
parentkernel: fix compilation with older gcc (diff)
downloadyuzu-f3b532d0915feb763f09b4900511c735c6b60693.tar
yuzu-f3b532d0915feb763f09b4900511c735c6b60693.tar.gz
yuzu-f3b532d0915feb763f09b4900511c735c6b60693.tar.bz2
yuzu-f3b532d0915feb763f09b4900511c735c6b60693.tar.lz
yuzu-f3b532d0915feb763f09b4900511c735c6b60693.tar.xz
yuzu-f3b532d0915feb763f09b4900511c735c6b60693.tar.zst
yuzu-f3b532d0915feb763f09b4900511c735c6b60693.zip
-rw-r--r--src/core/hle/kernel/k_capabilities.cpp8
-rw-r--r--src/core/hle/kernel/physical_core.h1
2 files changed, 5 insertions, 4 deletions
diff --git a/src/core/hle/kernel/k_capabilities.cpp b/src/core/hle/kernel/k_capabilities.cpp
index 64f1d7371..2907cc6e3 100644
--- a/src/core/hle/kernel/k_capabilities.cpp
+++ b/src/core/hle/kernel/k_capabilities.cpp
@@ -203,23 +203,23 @@ Result KCapabilities::ProcessMapRegionCapability(const u32 cap, F f) {
Result KCapabilities::MapRegion_(const u32 cap, KPageTable* page_table) {
// Map each region into the process's page table.
- R_RETURN(ProcessMapRegionCapability(
+ return ProcessMapRegionCapability(
cap, [](KMemoryRegionType region_type, KMemoryPermission perm) -> Result {
// R_RETURN(page_table->MapRegion(region_type, perm));
UNIMPLEMENTED();
R_SUCCEED();
- }));
+ });
}
Result KCapabilities::CheckMapRegion(KernelCore& kernel, const u32 cap) {
// Check that each region has a physical backing store.
- R_RETURN(ProcessMapRegionCapability(
+ return ProcessMapRegionCapability(
cap, [&](KMemoryRegionType region_type, KMemoryPermission perm) -> Result {
R_UNLESS(kernel.MemoryLayout().GetPhysicalMemoryRegionTree().FindFirstDerived(
region_type) != nullptr,
ResultOutOfRange);
R_SUCCEED();
- }));
+ });
}
Result KCapabilities::SetInterruptPairCapability(const u32 cap) {
diff --git a/src/core/hle/kernel/physical_core.h b/src/core/hle/kernel/physical_core.h
index fb2ba4c6b..fb8e7933e 100644
--- a/src/core/hle/kernel/physical_core.h
+++ b/src/core/hle/kernel/physical_core.h
@@ -3,6 +3,7 @@
#pragma once
+#include <condition_variable>
#include <cstddef>
#include <memory>
#include <mutex>